package com.etc.traval.bizimpl;

import java.util.List;

import com.etc.traval.biz.PlaceBiz;
import com.etc.traval.dao.PlaceDao;
import com.etc.traval.daoimpl.PlaceDaoImpl;
import com.etc.travel.entity.Place;

public class PlaceBizImpl implements PlaceBiz{

	PlaceDao dao=new PlaceDaoImpl();
	
	@Override
	public Place queryPlaceById(int id) {
		return dao.queryPlaceById(id);
	}

	@Override
	public List<Place> queryAllPlace(int page,int size) {
		return dao.queryAllPlace(page, size);
	}

	@Override
	public boolean addPlace(Place place) {
		return dao.addPlace(place);
	}

	@Override
	public boolean deletePlaceById(int id) {
		return dao.deletePlaceById(id);
	}

	@Override
	//根据id修改
    public boolean updatePlaceById(Place place, int id) {
		return dao.updatePlaceById(place, id);
	}

	@Override
	public List<Place> queryPlaceByName(String name,int page,int size) {
		return dao.queryPlaceByName(name, page, size);
	}

	@Override
	public List<Place> queryAllByNameKey(String key) {
		return dao.queryAllByNameKey(key);
	}
}
